<template>
    <view>
        子组件
        <button @click="sendToy(a)">按钮</button>
    </view>
</template>

<script setup>
import { ref } from 'vue';
    let a = ref(1)
    defineProps(['sendToy'])
</script>

<style lang="scss">

</style>